<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ include file="../common/taglibs.jsp"%>
<%@ include file="RolePowerManager.jsp"%>


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<link rel="stylesheet" href="${ctx}/css/common.css" type="text/css"></link>
  <link rel="stylesheet" href="${ctx}/css/reset.css" type="text/css"></link>
  <script type="text/javascript" src="${ctx}/js/jquery-1.7.2.js"></script>
  <script type="text/javascript" src="${ctx}/js/jquery.easydrag.handler.beta2.js"></script>
  <script type="text/javascript" src="${ctx}/js/My97DatePicker/WdatePicker.js"></script>
  <script type='text/javascript' src='${ctx}/dwr/interface/ResumeManagerService.js'></script>
  <script type='text/javascript' src='${ctx}/dwr/interface/DeptManager.js'></script>
  <script type='text/javascript' src='${ctx}/dwr/interface/DutyManager.js'></script>
  <script type='text/javascript' src='${ctx}/dwr/interface/EducationManager.js'></script>
  <script type='text/javascript' src='${ctx}/dwr/engine.js'></script>
  <script type='text/javascript' src='${ctx}/dwr/util.js'></script>
  <script type=text/javascript>
    var clock = new Clock();
    clock.display(document.getElementById("clock"));
  </script>
<script type="text/javascript" src="${ctx}/js/Dossier/ResumeManager.js"></script>
</head>
<body>
	<TABLE cellSpacing=0 cellPadding=0 width="100%" align=center border=0>
			<TR height=28>
				<TD background=${ctx}/images/title_bg1.jpg style="FONT-SIZE: 12px;">
					当前位置:人员档案管理 >> 人员履历
				</TD>
			</TR>
			<TR>
				<TD bgColor=#b1ceef height=1></TD>
			</TR>
			<TR height=20>
				<TD background=${ctx}/images/shadow_bg.jpg></TD>
			</TR>
		</TABLE>
	  <form action="GetResumeServlet" method="post" id="searchform">
	  <div class="query" >
	  <div class="querytype">
	  	<label>查询条件：</label>
	  	<select class="queryselect" name="searchtype" id="searchtype">
			<option value="empid">
			员工号
			</option>
			<option value="deptn">
			部门
			</option>
			<option value="dutyn">
			职位
			</option>
			<option value="edun">
			学历
			</option>
		</select>
		<input class="queryinput" type="text" name="keycode" id="keycode"/>
	  </div>
	  <div class="querytime">
	  	<div class="selecttime">
	  		<span class="STYLE1"><img src="${ctx}/images/a1.gif" width="9" height="9" /></span>
            <span class="STYLE1"> </span><a href="javaScript:search()" style="cursor: pointer;">查询</a><span class="STYLE1"></span>
	  	</div>
      </div>
      <div style="float: right; padding-right: 20px">
		<span class="STYLE1"><img src="${ctx}/images/001.gif" width="9" height="9" /></span>
       	<span class="STYLE1"> </span><a href="javaScript:clickAddResume('add_div')">新增</a><span class="STYLE1"></span>
	  </div>
	  <div class="clear"></div>
	  </div>
	  </form>
        <div class="bottom" ></div>
        <div id="main">
        <table id="detail_t">
          <tr>
          <th>序号</th>
            <th>员工号</th>
            <th>部门</th>
            <th>职位</th>
            <th>学历</th>
            <th>工作内容</th>
            <th>主要成绩</th>
            <th>开始时间</th>
            <th>结束时间</th>
            <th>更多操作</th>
          </tr>
          <c:forEach items="${page.list}" var="t" varStatus="stat">
          	<tr class="items">
	          <td >${stat.count}</td>
	          	<td id="${stat.count}${1}">${t.emp.empno}</td>
	          	<td id="${stat.count}${2}">${t.dept.name}</td>
	          	<td id="${stat.count}${3}">${t.duty.name}</td>
	          	<td id="${stat.count}${4}">${t.education.name}</td>
	       	   <td id="${stat.count}${5}">${t.workcontent}</td>
	          	<td id="${stat.count}${6}">${t.score}</td>
	          	<td id="${stat.count}${7}">${t.starttime}</td>
	          	<td id="${stat.count}${8}">${t.endtime}</td>
	            <td height="18" bgcolor="#FFFFFF">
	            <div align="center">
	            <span class="STYLE1"><img src="${ctx}/images/037.gif" width="9" height="9" /></span>
	             <span class="STYLE1"> [</span><a href="javaScript:clickEditResume('${stat.count}','${t.id}','edit_div')">编辑</a><span class="STYLE1">]</span>
	            &nbsp;&nbsp;&nbsp;
	            <span class="STYLE2"><img src="${ctx}/images/010.gif" width="9" height="9" /></span>
	            <span class="STYLE2"> </span><span class="STYLE1">[</span><a href="javaScript:deleteResume('${t.id}')">删除</a><span class="STYLE1">]</span>
	            </div>
	            </td>
          	</tr>
          </c:forEach>
        </table>
		  <div class="manu">
			共${page.totalCount}条记录当前第<font color="#ff6600">${page.pageNo}/${page.pageCount}</font>页
			<a href="GetResumeServlet?pageNo=${1}">首页</a><a href="GetResumeServlet?pageNo=${page.pageNo-1}">上一页</a><a href="GetResumeServlet?pageNo=${page.pageNo+1}">下一页</a><a href="GetResumeServlet?pageNo=${page.pageCount}">末页
			</a>每页显示<input type="text" name="pageSize" id="pageSize" size="2" />条 
			<input type="submit" onclick="changePageSize()" value="提交" />
		  </div>
		</div>
		<div id="edit_div" class="pop_box">
			<div class="p_head">
				<span class="p_h_title">员工详情</span>
				<span><a class="p_h_close" onclick="hideDiv('edit_div');"
					title="close">X</a> </span>
			</div>
			<div class="p_box_body" id="p_b_body">
								<div class="p_con">
					<table id="p_con_t">
						<tr>
							<td class="t1">
								人员ID：
							</td>
							<td>
								<div class="txt-fld">
									<input id="empid_edit" value="sddd" type="text" />
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								部门：
							</td>
							<td>
								<div class="txt-fld">
									<select id="deptname_edit">
										
									</select>
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								职位：
							</td>
							<td>
								<div class="txt-fld">
									<select id="dutyname_edit" >
									</select>
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								学历：
							</td>
							<td>
								<div class="txt-fld">
									<select id="eduname_edit">
									</select>
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								工作内容：
							</td>
							<td>
								<div class="txt-fld">
									<input id="workcon_edit" type="text" />
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								主要成绩：
							</td>
							<td>
								<div class="txt-fld">
									<input id="score_edit" type="text" />
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								开始时间：
							</td>
							<td>
								<div class="txt-fld">
									<input id="st_edit" type="text" onclick="WdatePicker();"/>
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								结束时间：
							</td>
							<td>
								<div class="txt-fld">
									<input id="et_edit" type="text"  onclick="WdatePicker();"/>
								</div>
							</td>
						</tr>
						<tr>
							<td></td>
							<td>
								<input style="visibility:hidden;width:0;height:0;" id="resumeid"/>
								<input type="button" value="提交" onclick="updateResume();"/>
							</td>
						</tr>
					</table>
				</div>

			</div>
		</div>
		<div id="add_div" class="pop_box">
			<div class="p_head">
				<span class="p_h_title">新增员工履历</span>
				<span><a class="p_h_close" onclick="hideDiv('add_div');"title="close">X</a> </span>
			</div>
			<div class="p_box_body" id="p_b_body">
				<div class="p_con">
					<table id="p_con_t">
						<tr>
							<td class="t1">
								人员ID：
							</td>
							<td>
								<div class="txt-fld">
									<input id="empid_add" type="text" />
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								部门：
							</td>
							<td>
								<div class="txt-fld">
									<select id="deptname_add">
									</select>
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								职位：
							</td>
							<td>
								<div class="txt-fld">
									<select id="dutyname_add">
									</select>
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								学历：
							</td>
							<td>
								<div class="txt-fld">
									<select id="eduname_add">
									</select>
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								工作内容：
							</td>
							<td>
								<div class="txt-fld">
									<input id="workcon_add" type="text" />
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								主要成绩：
							</td>
							<td>
								<div class="txt-fld">
									<input id="score_add" type="text" />
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								开始时间：
							</td>
							<td>
								<div class="txt-fld">
									<input id="st_add" type="text" onclick="WdatePicker();"/>
								</div>
							</td>
						</tr>
						<tr>
							<td class="t1">
								结束时间：
							</td>
							<td>
								<div class="txt-fld">
									<input id="et_add" type="text"  onclick="WdatePicker();"/>
								</div>
							</td>
						</tr>
						<tr>
							<td></td>
							<td>
								<input type="button" value="提交" onclick="addResume();"/>
							</td>
						</tr>
					</table>
				</div>
			</div>
		</div>
</body>
</html>